{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 导入数据集"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 44,
   "metadata": {},
   "outputs": [],
   "source": [
    "from warnings import simplefilter\n",
    "simplefilter(action='ignore', category=FutureWarning)\n",
    "#防止在运行过程中会出现不必要的警告"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 25,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Index(['Pregnancies', 'Glucose', 'BloodPressure', 'SkinThickness', 'Insulin',\n",
      "       'BMI', 'DiabetesPedigreeFunction', 'Age', 'Outcome'],\n",
      "      dtype='object')\n"
     ]
    }
   ],
   "source": [
    "import pandas as pd\n",
    "diabetes = pd.read_csv(\"diabetes.csv\")\n",
    "print(diabetes.columns)  # check the column name \n",
    "#前8列为数据特征（怀孕次数，血糖，血压，皮脂厚度，胰岛素，BMI身体质量指数，糖尿病遗传函数，年龄），最后一列为标签（结果）"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Pregnancies</th>\n",
       "      <th>Glucose</th>\n",
       "      <th>BloodPressure</th>\n",
       "      <th>SkinThickness</th>\n",
       "      <th>Insulin</th>\n",
       "      <th>BMI</th>\n",
       "      <th>DiabetesPedigreeFunction</th>\n",
       "      <th>Age</th>\n",
       "      <th>Outcome</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>6</td>\n",
       "      <td>148</td>\n",
       "      <td>72</td>\n",
       "      <td>35</td>\n",
       "      <td>0</td>\n",
       "      <td>33.6</td>\n",
       "      <td>0.627</td>\n",
       "      <td>50</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>85</td>\n",
       "      <td>66</td>\n",
       "      <td>29</td>\n",
       "      <td>0</td>\n",
       "      <td>26.6</td>\n",
       "      <td>0.351</td>\n",
       "      <td>31</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>8</td>\n",
       "      <td>183</td>\n",
       "      <td>64</td>\n",
       "      <td>0</td>\n",
       "      <td>0</td>\n",
       "      <td>23.3</td>\n",
       "      <td>0.672</td>\n",
       "      <td>32</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>1</td>\n",
       "      <td>89</td>\n",
       "      <td>66</td>\n",
       "      <td>23</td>\n",
       "      <td>94</td>\n",
       "      <td>28.1</td>\n",
       "      <td>0.167</td>\n",
       "      <td>21</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0</td>\n",
       "      <td>137</td>\n",
       "      <td>40</td>\n",
       "      <td>35</td>\n",
       "      <td>168</td>\n",
       "      <td>43.1</td>\n",
       "      <td>2.288</td>\n",
       "      <td>33</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   Pregnancies  Glucose  BloodPressure  SkinThickness  Insulin   BMI  \\\n",
       "0            6      148             72             35        0  33.6   \n",
       "1            1       85             66             29        0  26.6   \n",
       "2            8      183             64              0        0  23.3   \n",
       "3            1       89             66             23       94  28.1   \n",
       "4            0      137             40             35      168  43.1   \n",
       "\n",
       "   DiabetesPedigreeFunction  Age  Outcome  \n",
       "0                     0.627   50        1  \n",
       "1                     0.351   31        0  \n",
       "2                     0.672   32        1  \n",
       "3                     0.167   21        0  \n",
       "4                     2.288   33        1  "
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "diabetes.head()#输出数据集前5行，检测一下数据集读入的正确性"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "dimension of diabetes data: (768, 9)\n",
      "Outcome\n",
      "0    500\n",
      "1    268\n",
      "dtype: int64\n"
     ]
    }
   ],
   "source": [
    "print(\"dimension of diabetes data: {}\".format(diabetes.shape))#csv文件的行数和列数\n",
    "print(diabetes.groupby('Outcome').size())#\"Outcome\"这一列中0，1的统计情况，0意味着未患糖尿病，1意味着患有糖尿病\n",
    "#数据集位768 × 9的矩阵，在768个样本中，500个被标记为0，268个标记为1。"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYUAAAEGCAYAAACKB4k+AAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8vihELAAAACXBIWXMAAAsTAAALEwEAmpwYAAAPlklEQVR4nO3df6xfd13H8edrHWwgLK72bpa2o4sWtRUYelPR/SFuhNVfdKIjJfyosKQmTgU0mg6N+CNNFgUUgREbhXU4WSq/VvhDba78CD/LLY5t3aitG3Y3rW03VMBIteXtH/f0w7e9t90X1nO/d73PR9Kcc97fzzl93+amr5xzvudzUlVIkgRwwagbkCTNH4aCJKkxFCRJjaEgSWoMBUlSc+GoG3g8lixZUitXrhx1G5L0hLJ79+5Hqmpsts+e0KGwcuVKJicnR92GJD2hJPm3M33m5SNJUmMoSJIaQ0GS1BgKkqTG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kruS7Evyr0ne2j23cbZ93jBX/UlzxVDQgpckwAeAD1XVKuBZwNOALY+xq6Gg846hIME1wDeq6t0AVXUCeD3wmiS/muTtJwcm+UiSFyS5BXhKkruT3NF99qok9yT5YpL3dLVnJpno6hNJrujqtyV5Z5KPJnkwyU927w54IMltA3/fi5J8JskXkvxdkqfN2b+KFiRDQYI1wO7BQlV9FTgAXDjbDlW1Gfifqrqqql6eZA3wu8A1VfVc4LXd0LcDt1fVc4A7gL8YOMylTAfS64EPA3/W9fLsJFclWQL8HvDCqvoRYBL4zXPxA0tnMusvvLTAhNlnhj1TfTbXAO+rqkcAqurkOwB+HHhJt/4e4E8G9vlwVVWSe4HDVXUvQJI9wEqmJydcDXxq+goXT2Z6ygepN4aCBHuAXxwsJLmE6dlj/4tTz6gvPsMxhg2QwTHHuuU3B9ZPbl8InAB2VtXLhjiudE54+UiCCeCpSV4F7RWlb2b6VZAPAlcluSDJCqbfVHfS/yV50sAxXprke7pjLO7qn2Z65lmAlwOf/Db6+ixwdZLv74751CTP+nZ/OOnbYShowavpWSF/AbghyT7gX4BvMP3tok8BDwH3Am8CvjCw61bgniR3dDPLbgE+nuSLwFu6Mb8BvDrJPcAr+da9hmH6Ogr8MvDebv/PAj/4nf6c0jCcJVWS1HimIElqDAVJUmMoSJIaQ0GS1BgKkqTGUJAkNYaCJKn5f60kxS3wfCTcAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "import seaborn as sns\n",
    "import matplotlib.pyplot as plt\n",
    "sns.countplot(diabetes['Outcome'], label=\"Count\")\n",
    "plt.savefig(\"Outcome显示\")"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 划分为训练集和测试集"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<class 'pandas.core.frame.DataFrame'>\n",
      "RangeIndex: 768 entries, 0 to 767\n",
      "Data columns (total 9 columns):\n",
      " #   Column                    Non-Null Count  Dtype  \n",
      "---  ------                    --------------  -----  \n",
      " 0   Pregnancies               768 non-null    int64  \n",
      " 1   Glucose                   768 non-null    int64  \n",
      " 2   BloodPressure             768 non-null    int64  \n",
      " 3   SkinThickness             768 non-null    int64  \n",
      " 4   Insulin                   768 non-null    int64  \n",
      " 5   BMI                       768 non-null    float64\n",
      " 6   DiabetesPedigreeFunction  768 non-null    float64\n",
      " 7   Age                       768 non-null    int64  \n",
      " 8   Outcome                   768 non-null    int64  \n",
      "dtypes: float64(2), int64(7)\n",
      "memory usage: 54.1 KB\n"
     ]
    }
   ],
   "source": [
    "from sklearn.model_selection import train_test_split\n",
    "diabetes.info()     # get the diatebes' info\n",
    "x_train, x_test, y_train, y_test = train_test_split(\n",
    "    diabetes.loc[:, diabetes.columns != 'Outcome'],\n",
    "    diabetes['Outcome'], stratify=diabetes['Outcome'],\n",
    "    random_state=66)\n",
    "#x为特征，y为标签结果\n",
    "# X_train, X_test, y_train, y_test = train_test_split(data,target, test_size=0.3, random_state=4)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 导入包"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {
    "scrolled": true
   },
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "from imblearn.over_sampling import SMOTE #合成少数类过采样技术\n",
    "\n",
    "#机器学习所针对的问题有两种：一种是回归，一种是分类。\n",
    "#回归解决连续数据的预测问题，而分类解决离散数据的预测问题。\n",
    "from sklearn.neighbors import KNeighborsClassifier #KNN算法\n",
    "from sklearn.linear_model import LogisticRegression #线性回归  解决连续数据的预测问题\n",
    "from sklearn.tree import DecisionTreeClassifier#决策树\n",
    "from sklearn.ensemble import RandomForestClassifier#随机森林分类模型\n",
    "from sklearn.ensemble import  GradientBoostingClassifier#梯度提升树模型\n",
    "from sklearn.svm import SVC #支持向量机 按监督学习方式对数据进行二元分类的广义线性分类器\n",
    "from sklearn.neural_network import MLPClassifier #MLP模型，多层感知机，人工神经网络\n",
    "\n",
    "\n",
    "\n",
    "from sklearn.model_selection import StratifiedKFold#分层抽样\n",
    "from sklearn.preprocessing import StandardScaler, MinMaxScaler#数据标准化\n",
    "from sklearn.metrics import precision_score, recall_score, roc_auc_score, average_precision_score, f1_score#\n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### KNN算法预测"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYgAAAEHCAYAAAC0pdErAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8vihELAAAACXBIWXMAAAsTAAALEwEAmpwYAAA3O0lEQVR4nO3deXxU9b3/8dcnG9kDISFhFcQokEAgBBRwAYUktHWhWitu1VYRt2sXvdXe29rl+ru2tZvWpehVW2tdqqK2skQUXBCVIAgJi4RFCDEkIRASQkKWz++PM4QQJskAmZxJ+DwfjzwmM3POmU8Gnfd8v+d7vl9RVYwxxpjWgtwuwBhjTGCygDDGGOOVBYQxxhivLCCMMcZ4ZQFhjDHGqxC3C+hMCQkJOnToULfLMMaYbmPVqlXlqpro7bkeFRBDhw4lLy/P7TKMMabbEJEv23rOupiMMcZ4ZQFhjDHGKwsIY4wxXvWocxDGmONXX19PUVERtbW1bpdi/Cg8PJxBgwYRGhrq8z4WEMac4oqKioiJiWHo0KGIiNvlGD9QVfbs2UNRURHDhg3zeT+/dTGJyNMiUioi+W08LyLysIgUishaEclo8VyOiGzyPHevv2o0xkBtbS19+/a1cOjBRIS+ffsedyvRn+cgngVy2nl+JpDi+ZkDPA4gIsHAo57nRwGzRWSUH+s05pRn4dDznci/sd8CQlXfByra2eRS4G/q+BjoLSL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NaZTWUCYU4qIDPUsuvOkZ9GZXBGJaGPbZSLyaxH5VES+EJHzPI8Hi8hvRWSliKwVkVtaHDvf83ukiLzsef4lEflERDJbHPsBEflcRD4WkaQWLztdRD7wvN43PNuGi8gzIrLOM6PrNM/jN4jIP0XkX0CuiPQXkfdFZI1nMZ3z/PMumlOFBYQ5FaUAj6pqKrAPuLydbUNUdSLwfZwpDQC+hzPN9ARgAnCziAxrtd9twF5VHQP8Chjf4rko4GNVTQfeB25u8dxQ4AKc9TCe8KyWdjuAqo4GZgN/bbGK2iTgO6p6IXA1sFhVx+IsLLSmozfCmPZYs9Scirap6hrP76twPpTb8pqX7bKAMS3OF8ThhM4XLfY7F2clOFQ1X0TWtnjuEHB4KdVVwIwWz72sqk3AZhHZCozwHOsRz7E2isiXwJme7d9W1cOLx6wEnvbMDPx6i7/RmBNiLQhzKqpr8Xsj7X9RqvOynQB3qupYz88wL4vWSDvHrNcjk6C1fv3Wk6NpB8c60Lyhs9LY+cAu4DkRub6d/YzpkAWEMcdvMXCr55s6InKml1XePgSu9Dw/Chjt47G/JSJBIjIcZzW5TTjdUNccfi1giOfxo4jIaTiLLT2JM338qbxuhOkE1sVkzPF7Cqe76TPPmgRlHLsG8GM45wrW4kxJvRao9OHYm4D3gCRgrqrWishjOOcj1uFMcX2DqtY5L32UqcA9IlIPVAPWgjAnxab7NsYPRCQYCPV8wA8H3gHOVNVDLpdmjM+sBWGMf0QCSz3dUALcauFguhtrQZhTnog8irOqX0t/UtVn3KjHmEBhAWGMMcYrG8VkjDHGKwsIY4wxXllAGGOM8coCwhhjjFf/H0OW5kMfwNdZAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "# y_pred1 = clf1.fit(X_train, y_train).predict(X_test)\n",
    "# y_pred2 = clf2.fit(X_train, y_train).predict(X_test)\n",
    "# y_pred3 = clf3.fit(X_train, y_train).predict(X_test)\n",
    "training_accuracy = []\n",
    "test_accuracy = []\n",
    "# 尝试近邻点 from 1 to 10\n",
    "neighbors_settings = range(1, 11)\n",
    "for n_neighbors in neighbors_settings:\n",
    "    knn = KNeighborsClassifier(n_neighbors=n_neighbors)  # 建立模型\n",
    "    knn.fit(x_train, y_train)  # 模型训练\n",
    "    training_accuracy.append(knn.score(x_train, y_train))  # 记录训练集 准确率\n",
    "    test_accuracy.append(knn.score(x_test, y_test))  # 记录测试集 准确率\n",
    "\n",
    "'''\n",
    "模型预测准确度（y轴）和近邻点个数（x轴）设置之间的关系\n",
    "'''\n",
    "plt.figure()\n",
    "plt.plot(neighbors_settings, training_accuracy, label=\"training accuracy\")\n",
    "plt.plot(neighbors_settings, test_accuracy, label=\"test accuracy\")\n",
    "plt.ylabel(\"Accuracy\")\n",
    "plt.xlabel(\"n_neighbors\")\n",
    "plt.legend()\n",
    "plt.savefig(\"KNN预测准确度\")\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [
    {
     "ename": "NameError",
     "evalue": "name 'KNeighborsClassifier' is not defined",
     "output_type": "error",
     "traceback": [
      "\u001b[1;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[1;31mNameError\u001b[0m                                 Traceback (most recent call last)",
      "\u001b[1;32m<ipython-input-1-865d971583ad>\u001b[0m in \u001b[0;36m<module>\u001b[1;34m\u001b[0m\n\u001b[0;32m      1\u001b[0m \u001b[1;31m#为了使训练集和测试集的准确度都最高，我们选择9个邻近点，即n_neghbors=9\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m----> 2\u001b[1;33m \u001b[0mknn\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mKNeighborsClassifier\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mn_neighbors\u001b[0m\u001b[1;33m=\u001b[0m\u001b[1;36m9\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m      3\u001b[0m \u001b[0mknn\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mfit\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mx_train\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0my_train\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m      4\u001b[0m \u001b[0mx_test\u001b[0m\u001b[1;33m=\u001b[0m\u001b[1;33m[\u001b[0m\u001b[1;36m6\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;36m148\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;36m72\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;36m35\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;36m0\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;36m33.6\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;36m0.627\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;36m50\u001b[0m\u001b[1;33m]\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m      5\u001b[0m \u001b[0mprint\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m\"knn算法预测结果：\"\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0mknn\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mfit\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mx_train\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0my_train\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mpredict\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mx_test\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;31mNameError\u001b[0m: name 'KNeighborsClassifier' is not defined"
     ]
    }
   ],
   "source": [
    "#为了使训练集和测试集的准确度都最高，我们选择9个邻近点，即n_neghbors=9\n",
    "knn = KNeighborsClassifier(n_neighbors=9)\n",
    "knn.fit(x_train, y_train)\n",
    "x_test=[6,148,72,35,0,33.6,0.627,50]\n",
    "print(\"knn算法预测结果：\",knn.fit(x_train, y_train).predict(x_test))\n",
    "print(\"Accuracy of K-NN classifier on training set: {:.2f}\".format(knn.score(x_train, y_train)))\n",
    "print(\"Accuracy of K-NN classifier on test set: {:.2f}\".format(knn.score(x_test, y_test)))"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 线性逻辑回归"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "线性回归预测结果： [1 0 0 0 0 1 1 0 0 0 1 0 1 0 1 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n",
      " 1 1 0 1 0 0 0 1 0 0 1 0 1 1 1 0 0 1 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0\n",
      " 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 1 1 1 0 1 0 0 0 0 0 1 0 0 0 0 0 0 1 0 0 1\n",
      " 0 1 0 0 1 0 1 0 0 0 0 0 1 0 1 1 0 1 0 0 1 0 0 0 0 0 0 1 0 0 1 1 1 1 0 0 1\n",
      " 0 0 0 0 1 0 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 1 1 1\n",
      " 0 0 0 0 1 0 0]\n",
      "Training set score : 0.781\n",
      "Test set score: 0.771\n"
     ]
    }
   ],
   "source": [
    "from sklearn.linear_model import LogisticRegression\n",
    "# 正则化参数C=1（默认值）的模型精度为78%训练集和77%的测试集\n",
    "logreg = LogisticRegression(solver='liblinear').fit(x_train, y_train)\n",
    "print(\"线性回归预测结果：\",logreg.predict(x_test))\n",
    "print(\"Training set score : {:.3f}\".format(logreg.score(x_train, y_train)))\n",
    "print(\"Test set score: {:.3f}\".format(logreg.score(x_test, y_test)))\n",
    "#对数据再进行逻辑回归训练,得到的训练准确度."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 22,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Training set score : 0.785\n",
      "Test set score: 0.766\n"
     ]
    }
   ],
   "source": [
    "#调参\n",
    "#设置正则化参数C的值，默认值为1，当我们设置为C=100时\n",
    "logreg100 = LogisticRegression(C=100, solver='liblinear').fit(x_train, y_train)\n",
    "print(\"Training set score : {:.3f}\".format(logreg100.score(x_train, y_train)))\n",
    "print(\"Test set score: {:.3f}\".format(logreg100.score(x_test, y_test)))\n",
    "#训练集的准确度有所提升但测试集的准确度下降，说明C=1比C=100好."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 23,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Training set score : 0.686\n",
      "Test set score: 0.714\n"
     ]
    }
   ],
   "source": [
    "#调参\n",
    "#当我们设置为C=0.001时\n",
    "logreg001 = LogisticRegression(C=0.001, solver='liblinear').fit(x_train, y_train)\n",
    "print(\"Training set score : {:.3f}\".format(logreg001.score(x_train, y_train)))\n",
    "print(\"Test set score: {:.3f}\".format(logreg001.score(x_test, y_test)))\n",
    "#训练集和测试集的准确度都有所下降"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 决策树"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 29,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 1.000\n",
      "Accuract on test set: 0.714\n"
     ]
    }
   ],
   "source": [
    "from sklearn.tree import DecisionTreeClassifier\n",
    "# decision tree\n",
    "tree = DecisionTreeClassifier(random_state=0)\n",
    "tree.fit(x_train, y_train)\n",
    "print(\"Accuracy on training set: {:.3f}\".format(tree.score(x_train, y_train)))\n",
    "print(\"Accuract on test set: {:.3f}\".format(tree.score(x_test, y_test)))\n",
    "#对数据集进行决策树分析，发现训练集的准确度达到了100%，而测试集的准确度只有71.4%。\n",
    "#所以我们要限制树的深度来减少过度拟合"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 30,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 0.773\n",
      "Accuract on test set: 0.740\n",
      "Feature importance:\n",
      "[0.04554275 0.6830362  0.         0.         0.         0.27142106\n",
      " 0.         0.        ]\n"
     ]
    }
   ],
   "source": [
    "#限制树的深度\n",
    "tree = DecisionTreeClassifier(max_depth=3, random_state=0)\n",
    "tree.fit(x_train, y_train)\n",
    "print(\"Accuracy on training set: {:.3f}\".format(tree.score(x_train, y_train)))\n",
    "print(\"Accuract on test set: {:.3f}\".format(tree.score(x_test, y_test)))\n",
    "print(\"Feature importance:\\n{}\".format(tree.feature_importances_))#每个特征对预测结果的重要性\n",
    "#训练集准确度有所降低，但测试集准确度升高了。\n",
    "#决策树中的特征重要性，用来衡量每个特征对预测结果的重要性"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 31,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAmQAAAFzCAYAAACQKhUCAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8vihELAAAACXBIWXMAAAsTAAALEwEAmpwYAAAmpklEQVR4nO3dfZxlVX3n+8/XbpDnJkKriGIroqiILRQo6iASQ1RUQDFqzChqJBrF0VzNmGTikGsSUZwZrzpGkVHUkWgUfAgQwIs8jDx3Q9PdIBhHMPFpBM1tBRGh+d0/zio9FNVdp+k+taiqz/v1Oq/aZ+211/6tOk33l7X3OSdVhSRJkvp5QO8CJEmSFjoDmSRJUmcGMkmSpM4MZJIkSZ0ZyCRJkjozkEmSJHW2uHcBWrh23XXXWrZsWe8yJEmaFStXrrylq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kSb+W5Hjg1qp6f+9apIXEFTJJkqTOXCGTJEnqzBUySZKkzgxkkiRJnRnIJEmSOjOQSZIkdWYgkyRJ6sxAJkmS1Nn/DxNbWgV8HxC7AAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 576x432 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "def plot_feature_importances_diatebes(model):\n",
    "    plt.figure(figsize=(8, 6))\n",
    "    n_features = 8\n",
    "    plt.barh(range(n_features), model.feature_importances_, align='center')\n",
    "    plt.yticks(np.arange(n_features), diabetes_features)\n",
    "    plt.xlabel(\"Features importance\")\n",
    "    plt.ylabel(\"Feature\")\n",
    "    plt.ylim(-1, n_features)\n",
    "\n",
    "\n",
    "plot_feature_importances_diatebes(tree)\n",
    "plt.savefig(\"决策树特征重要性\")\n",
    "#Glucose（葡萄糖）是目前最重要的特征，BMI（身体质量指数）为第二重要的信息特征"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 随机森林"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 32,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "\n",
      "Preliminary results of decision tree fitting:\n",
      "Accuracy on training set: 1.000\n",
      "Accuracy on test set: 0.786\n"
     ]
    }
   ],
   "source": [
    "from sklearn.ensemble import RandomForestClassifier, GradientBoostingClassifier\n",
    "rf = RandomForestClassifier(n_estimators=100, random_state=0)#使用100课树组成的随机森林对数据集进行分析\n",
    "rf.fit(x_train, y_train)\n",
    "print(\"\\nPreliminary results of decision tree fitting:\")\n",
    "print(\"Accuracy on training set: {:.3f}\".format(rf.score(x_train, y_train)))\n",
    "print(\"Accuracy on test set: {:.3f}\".format(rf.score(x_test, y_test)))\n",
    "#得到训练集的准确度为100%，测试集有78.6%\n",
    "#比逻辑回归和单一决策树都要好，调节max_depth的值，提高准确率"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 33,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "\n",
      "Finally results of decision tree fitting:\n",
      "Accuracy on training set: 0.800\n",
      "Accuracy on test set: 0.755\n"
     ]
    }
   ],
   "source": [
    "#调参，调节max_depth的值\n",
    "rf1 = RandomForestClassifier(max_depth=3, n_estimators=100, random_state=0)\n",
    "rf1.fit(x_train, y_train)\n",
    "print(\"\\nFinally results of decision tree fitting:\")\n",
    "print(\"Accuracy on training set: {:.3f}\".format(rf1.score(x_train, y_train)))\n",
    "print(\"Accuracy on test set: {:.3f}\".format(rf1.score(x_test, y_test)))\n",
    "#准确率有所下降，默认的max_depth较好"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 34,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAmQAAAFzCAYAAACQKhUCAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8vihELAAAACXBIWXMAAAsTAAALEwEAmpwYAAAmFElEQVR4nO3debhlVX3n//fHYp6KCEhKHK5DKSpoCQUK+CNoDBkwAopRm7SgRqJRbE1jfhg7NmmTiGJ322obRVpRW1qjohIggI0MLXMVFFSBYGwpO6JG0HQpgwzFt/846+qpy62qU9xhUfe+X89znrvP2nuv/d2LA35ce599UlVIkiSpn0f1LkCSJGm+M5BJkiR1ZiCTJEnqzEAmSZLUmYFMkiSpMwOZJElSZ1v0LkDz16677lpjY2O9y5AkaVYsX778jqrabbJ1BjJ1MzY2xrJly3qXIUnSrEjyvfWt85KlJElSZwYySZKkzgxkkiRJnRnIJEmSOjOQSZIkdWYgkyRJ6sxAJkmS1JmBTJIkqTMDmSRJUmcGMkmSpM4MZJIkSZ0ZyCRJkjozkEmSJHVmIJMkSerMQCZJktSZgUySJKkzA5kkSVJnBjJJkqTODGSSJEmdbdG7AM1fK29bw9iJ5/Q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HbfVeSf6KQXjagcFPtmyqr1fVT9vyocBLk5zQ3m8DPAG4AnhXkscBZ1bVP26kz1uramWr/0bgwqqqJCsZBKRxX6uqe4B7klzE4MeUXwD8j6paC/xzkkuA/YCfAVdX1a3rOWaAv0lyMPAgsAeDQDdez4q2vBwYy+B3A/eoqq8AVNUvWr2HtnG4rm2/A7AYuHQj5yxtFgxkkvTwBLixqg6YZN3pwBFVdX2SYxnMIk3mAX5168g2E9bdNeFYL6+qWyZs860kVwGHAecn+aOq+sYGar53aPnBofcPsu7/Hky8ubhaDetz1wbWHQ3sBuxbVfe3y7Lj5zpcz1oGs3LrO06A91bVxzdwLGmz5T1kkvTw3ALsluQAgCRbJnlWW7cj8MMkWzIIJON+3taNWw3s25aP2sCxzgeOT5uKS/Lc9vfJwHer6kPAWcCzp3RGv3J4km2S7MIgTF7DYCbqlUkWJNkNOBi4epJ9J57jQuDHLYy9EHjihg5cVT8Dvp/kCIAkWyfZjsEYvC7JDq19jySPmcpJSo8kBjJJehiq6j4GIep9Sa5ncG/ZgW31XzC4D+rrwM1Du30eeEe7Mf8pwAeANyW5nMH9VevzHgb3rN2QZFV7D4P71lYlWQHsCXxmGk4NBkHrHOBK4D1V9QMG983dwOD+sm8Af1ZVP5q4Y1X9BLis3fx/CvA5YGmSZQzC6c0T95nEvwbemuQGBvfp/XpVXQCcAVzRLrF+iXWDn7RZ87EXkqRfSnIScGdVfaB3LdJ84gyZJElSZ86QSZIkdeYMmSRJUmcGMkmSpM4MZJIkSZ0ZyCRJkjozkEmSJHVmIJMkSers/wHbQHm0NBpmiQAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 576x432 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "plot_feature_importances_diatebes(rf)\n",
    "plt.savefig(\"随机森林重要度\")\n",
    "#与决策树类似，特征\"Glucose\"（葡萄糖）的重要度最高，BMI（身体质量指数）为第二重要的信息特征。"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 梯度提升树"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 35,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "\n",
      "Preliminary results of decision tree fitting:\n",
      "Accuracy on training set: 0.917\n",
      "Accuracy on test set: 0.792\n"
     ]
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAmQAAAFzCAYAAACQKhUCAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8vihELAAAACXBIWXMAAAsTAAALEwEAmpwYAAAnCklEQVR4nO3de7hlVX3m++9rgdwpIqAp8bIVSlEBSyhQwEPQGGKCEVCM2qYFNRKNYmta0xg7NjkmEcXu9qhtFGlFbWmN4i1gAA9yablXYUEVCMaWsiNqFM0p5SJC8Tt/rLFl1XZX1Sr2ZdTe+/t5nv3sucacc8zfWLOKehlzrrlSVUiSJKmfh/QuQJIkaaEzkEmSJHVmIJMkSerMQCZJktSZgUySJKkzA5kkSVJn2/QuQAvXHnvsUWNjY73LkCRpVqxcufL2qtpzsnUGMnUzNjbGihUrepchSdKsSPLdja3zkqUkSVJnBjJJkqTODGSSJEmdGcgkSZI6M5BJkiR1ZiCTJEnqzEAmSZLUmYFMkiSpMwOZJElSZwYySZKkzgxkkiRJnRnIJEmSOjOQSZIkdWYgkyRJ6sxAJkmS1JmBTJIkqTMDmSRJUmcGMkmSpM4MZJIkSZ1t07sALVyrb1vH2Cnn9S5Dm7H2tKN7lyBJ854zZJIkSZ0ZyCRJkjozkEmSJHVmIJMkSerMQCZJktSZgUySJKkzA5kkSVJnBjJJkqTODGSSJEmdGcgkSZI6M5BpUkmOS1JJ9u1diyRJ852BTBvzUuDrwEt6FyJJ0nxnINOvSbIzcDjwKlogS/KQJB9McmOSc5N8Jcnxbd1BSS5NsjLJBUmWdCxf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AWe0fR8CnAsc0fvPhT/+TNePX50kSaO5u6qWjb9Ish+wH/DV9pUxi4AftNX7JflrBuFpZwZfv7KlvlpVP23LRwHPT/Lm9np7Bt/9eCXwtiSPAj5fVf+0mT5vrarVrf4bgYuqqpKsZhCQxn2pqu4G7k5yMYMvin4m8D+raj3wL0kuBQ4Gfsbgu1tv3cgxA/xtkiOA+4G9GAS68XpWteWVwFiSXYC9quoLAFX1i1bvUe19+EbbfmdgKXDZZsYszQkGMkl6cALcWFWHTrLuLODYqro+yYkMZpEmcx8P3Dqy/YR1d0441gur6pYJ23wzydUMvtz+giR/XFVf20TN9wwt3z/0+n42/Pdg4s3F1WrYmDs3se5lwJ7AQVV1b7ssOz7W4XrWM5iV29hxAryzqj68iWNJc5b3kEnSg3MLsGeSQwGSbJvkKW3dLsAPkmzLIJCM+3lbN24tcFBbPn4Tx7oAODltKi7J09rvxwPfqar3AV8GDpjSiB5wTJLtk+zOIExey2Am6sVJFiXZEzgCuGaSfSeOcTHwoxbGngU8dlMHrqqfAd9LcixAku2S7MjgPXhlkp1b+15JHj6VQUpbEwOZJD0IVfVLBiHqXUmuZ3Bv2WFt9V8yuA/qq8DNQ7t9GnhLuzF/b+A9wGuTXMHg/qqNeQeDe9ZuSLKmvYbBfWtrkqwC9gU+MQ1Dg0HQOg+4CnhHVX2fwX1zNzC4v+xrwJ9X1Q8n7lhVPwEubzf/nw58ClieZAWDcHrzxH0m8W+BNyS5gcF9er9ZVRcCZwNXtkusn2PD4CfNaT72QpL0K0lOBe6oqvf0rkVaSJwhkyRJ6swZMkmSpM6cIZMkSerMQCZJktSZgUySJKkzA5kkSVJnBjJJkqTODGSSJEmd/f/q0ZtFWwzFMQAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 576x432 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "from sklearn.ensemble import  GradientBoostingClassifier\n",
    "gb = GradientBoostingClassifier(random_state=0)\n",
    "gb.fit(x_train, y_train)\n",
    "print(\"\\nPreliminary results of decision tree fitting:\")\n",
    "print(\"Accuracy on training set: {:.3f}\".format(gb.score(x_train, y_train)))\n",
    "print(\"Accuracy on test set: {:.3f}\".format(gb.score(x_test, y_test)))\n",
    "plot_feature_importances_diatebes(gb)\n",
    "plt.savefig(\"梯度提升树重要度\")\n",
    "#训练准确度太高，可能过拟合\n",
    "#通过限制最大深度和降低学习效率来进行修减"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 36,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 0.804\n",
      "Accuracy on test set: 0.781\n"
     ]
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAmYAAAFzCAYAAACU38U/AAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8vihELAAAACXBIWXMAAAsTAAALEwEAmpwYAAAnIElEQVR4nO3debxlVX3n/c/XKuahiIBa4nAVClEGSyhQwCZACIliBBSDhrSgRiJRbM2DaYwdQ5okotjdPGobRVpRW1ojoBIggA8ytMxVUBMIxpYyETWC5illkKH49R9nXTxc7nAK6t6zq+7n/Xqd191n7bXX/p1VF+pba+9zTqoKSZIkDd/Thl2AJEmSegxmkiRJHWEwkyRJ6giDmSRJUkcYzCRJkjrCYCZJktQRc4ddgGav7bbbrkZGRoZdhiRJM2LJkiX3VNX2k/UxmGloRkZGWLx48bDLkCRpRiT5wVR9vJQpSZLUEQYzSZKkjjCYSZIkdYTBTJIkqSMMZpIkSR1hMJMkSeoIg5kkSVJHGMwkSZI6wmAmSZLUEQYzSZKkjjCYSZIkdYTBTJIkqSMMZpIkSR1hMJMkSeoIg5kkSVJHGMwkSZI6wmAmSZLUEQYzSZKkjjCYSZIkdcTcYReg2WvFXasZOfmiYZcxrVaddtiwS5AkrUdcMZMkSeoIg5kkS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kdYTCTJEnqiP8Lladuci5ODoMAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 576x432 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "#限制最大深度\n",
    "gb1 = GradientBoostingClassifier(max_depth=1, random_state=0)\n",
    "gb1.fit(x_train, y_train)\n",
    "print(\"Accuracy on training set: {:.3f}\".format(gb1.score(x_train, y_train)))\n",
    "print(\"Accuracy on test set: {:.3f}\".format(gb1.score(x_test, y_test)))\n",
    "plot_feature_importances_diatebes(gb1)\n",
    "plt.savefig('梯度提升树1')\n",
    "#降低了训练集的准确度，但没有提高测试集的准确度，需继续调参\n",
    "#Glucose”（葡萄糖）仍然是最重要的信息特征，\"BMI\"仍然是第二重要的信息特征"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 37,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 0.802\n",
      "Accuracy on test set: 0.776\n"
     ]
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAmQAAAFzCAYAAACQKhUCAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8vihELAAAACXBIWXMAAAsTAAALEwEAmpwYAAAmz0lEQVR4nO3de5xlVX3n/c/X5n5rIqC2eCmFRlTAFhoUdQgaQ6IYAcWoMaOokWgUR/NoBuPEIY9JRHFmfNQxioyijoxGwUuAAD7IZeTejU13g6COtImoUTRPKxcRmt/zx1klh6Kq6zTdVau76vN+vc6r9ll77bV/Z3VBf3vtfc5JVSFJkqR+HtK7AEmSpPnOQCZJktSZgUySJKkzA5kkSVJnBjJJkqTODGSSJEmdbdW7AM1fu+++e42NjfUuQ5KkWbF8+fJbq2qPyfYZyNTN2NgYy5Yt612GJEmzIsn3p9rnJUtJkqTODGSSJEmdGcgkSZI6M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VPwMuazf/nwJ8FliaZBmDcHrjxGMm8e+BNydZyeA+vUdU1QXAGcAV7RLrF7l/8JO2aH7shSTpN5KcBNxWVe/vXYs0n7hCJkmS1JkrZJIkSZ25QiZJktSZgUySJKkzA5kkSVJnBjJJkqTODGSSJEmdGcgkSZI6+/8BRKVYNmkf4bcAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 576x432 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "#降低学习效率\n",
    "gb2 = GradientBoostingClassifier(random_state=0, learning_rate=0.01)\n",
    "gb2.fit(x_train, y_train)\n",
    "print(\"Accuracy on training set: {:.3f}\".format(gb2.score(x_train, y_train)))\n",
    "print(\"Accuracy on test set: {:.3f}\".format(gb2.score(x_test, y_test)))\n",
    "plot_feature_importances_diatebes(gb2)\n",
    "plt.savefig(\"梯度提升树2\")\n",
    "#降低了训练集的准确度，但没有提高测试集的准确度，需继续调参\n",
    "#Glucose”（葡萄糖）仍然是最重要的信息特征，\"BMI\"仍然是第二重要的信息特征。"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### SVC 向量机"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 38,
   "metadata": {},
   "outputs": [],
   "source": [
    "#对数据进行类型处理\n",
    "x_train = x_train.astype(np.float64)\n",
    "y_train = y_train.astype(np.float64)\n",
    "x_test = x_test.astype(np.float64)\n",
    "y_test = y_test.astype(np.float64)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 39,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 0.77\n",
      "Accuracy on test set: 0.76\n"
     ]
    }
   ],
   "source": [
    "from sklearn.svm import SVC\n",
    "svc = SVC()\n",
    "svc.fit(x_train, y_train)\n",
    "print(\"Accuracy on training set: {:.2f}\".format(svc.score(x_train, y_train)))\n",
    "print(\"Accuracy on test set: {:.2f}\".format(svc.score(x_test, y_test)))\n",
    "#需要调整各特征值的尺度使其在同一量表上"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 40,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 0.79\n",
      "Accuracy on test set: 0.80\n"
     ]
    }
   ],
   "source": [
    "#调整各特征值的尺度使其在同一量表上\n",
    "from sklearn.preprocessing import MinMaxScaler\n",
    "scaler = MinMaxScaler()\n",
    "x_train_scaled = scaler.fit_transform(x_train)\n",
    "x_test_scaled = scaler.fit_transform(x_test)\n",
    "svc = SVC()\n",
    "svc.fit(x_train_scaled, y_train)\n",
    "print(\"Accuracy on training set: {:.2f}\".format(svc.score(x_train_scaled, y_train)))\n",
    "print(\"Accuracy on test set: {:.2f}\".format(svc.score(x_test_scaled, y_test)))\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 41,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 0.944\n",
      "Accuracy on test set: 0.724\n"
     ]
    }
   ],
   "source": [
    "#调参后，效果并不理想\n",
    "svc = SVC(C=1000)\n",
    "svc.fit(x_train_scaled, y_train)\n",
    "print(\"Accuracy on training set: {:.3f}\".format(svc.score(x_train_scaled, y_train)))\n",
    "print(\"Accuracy on test set: {:.3f}\".format(svc.score(x_test_scaled, y_test)))"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### MLP人工神经网络"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 42,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 0.73\n",
      "Accuracy on test set: 0.72\n"
     ]
    }
   ],
   "source": [
    "from sklearn.neural_network import MLPClassifier\n",
    "mlp = MLPClassifier(random_state=42)\n",
    "mlp.fit(x_train, y_train)\n",
    "print(\"Accuracy on training set: {:.2f}\".format(mlp.score(x_train, y_train)))\n",
    "print(\"Accuracy on test set: {:.2f}\".format(mlp.score(x_test, y_test)))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 45,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 0.823\n",
      "Accuracy on test set: 0.802\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "C:\\ProgramData\\Anaconda3\\lib\\site-packages\\sklearn\\neural_network\\_multilayer_perceptron.py:585: ConvergenceWarning: Stochastic Optimizer: Maximum iterations (200) reached and the optimization hasn't converged yet.\n",
      "  % self.max_iter, ConvergenceWarning)\n"
     ]
    }
   ],
   "source": [
    "#多层神经网络（MLP）的表现并没有其他的模型好，所以要对数据进行处理\n",
    "# Standardized data\n",
    "scaler = StandardScaler()\n",
    "x_train_scaled = scaler.fit_transform(x_train)\n",
    "x_test_scaled = scaler.fit_transform(x_test)\n",
    "mlp = MLPClassifier(random_state=0)\n",
    "mlp.fit(x_train_scaled, y_train)\n",
    "print(\"Accuracy on training set: {:.3f}\".format(mlp.score(x_train_scaled, y_train)))\n",
    "print(\"Accuracy on test set: {:.3f}\".format(mlp.score(x_test_scaled, y_test)))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 48,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 1.000\n",
      "Accuracy on test set: 0.771\n"
     ]
    }
   ],
   "source": [
    "#增加迭代次数\n",
    "mlp = MLPClassifier(max_iter=10000, random_state=0)\n",
    "mlp.fit(x_train_scaled, y_train)\n",
    "print(\"Accuracy on training set: {:.3f}\".format(mlp.score(x_train_scaled, y_train)))\n",
    "print(\"Accuracy on test set: {:.3f}\".format(mlp.score(x_test_scaled, y_test)))\n",
    "#增加迭代次数只是增加了训练集的准确度，而测试集的准确度还降低了"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 49,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Accuracy on training set: 0.806\n",
      "Accuracy on test set: 0.797\n"
     ]
    }
   ],
   "source": [
    "#调高alpha参数并且加强权重的正则化\n",
    "mlp = MLPClassifier(max_iter=10000, alpha=1, random_state=0)\n",
    "mlp.fit(x_train_scaled, y_train)\n",
    "print(\"Accuracy on training set: {:.3f}\".format(mlp.score(x_train_scaled, y_train)))\n",
    "print(\"Accuracy on test set: {:.3f}\".format(mlp.score(x_test_scaled, y_test)))\n",
    "#结果比增加迭代次数好，但没有第一次结果好"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 51,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAABIcAAAEnCAYAAAAzVSPSAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8vihELAAAACXBIWXMAAAsTAAALEwEAmpwYAABEz0lEQVR4nO3dd5xcdb3/8fc7m7IppJFCSAKhhCYlQAARVEBQQC/FcgHxB9i4egVBLt6Lei/iVa9YrtcuRkWwF0CpUkSQDqGEhIReAiFACiQkpO9+fn/MWZ0su/OZyWazZV7Px2MeO3POZ77ne86cOTP7mW9xRAgAAAAAAAD1qU9XVwAAAAAAAABdh+QQAAAAAABAHSM5BAAAAAAAUMdIDgEAAAAAANQxkkMAAAAAAAB1jOQQAAAAAABAHSM5BAAAAAAA0E3YPtz2o7afsH1OG+uPtj3T9gzb99o+sMPbjIiOlgEAAAAAAIAOst0g6TFJh0maJ2m6pBMiYk5ZzBBJr0VE2N5d0u8jYqeObJeWQwAAAAAAAN3DvpKeiIinImKNpN9KOro8ICKWxz9a+gyW1OFWPySHAAAAAAAAuofxkp4rezyvWLYe28fafkTS1ZI+1NGN9u1oAQAAAAAAAPXkHQcPjsUvN9X8vPtmrp4taVXZomkRMa3ssdt42utaBkXEHyX90fZbJH1R0qE1V6YMySEAAAAAAIAaLHq5SXdfN6Hm5/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knF/dPlnR56wDbo4sWQ7I9UNKhkh7JCqZbGQAAAAAAQDdne3NJv5e0laRnJb0vIl62vaWkn0TEkbZ3V2mw6gaVGgT9PiL+Oy2b5BAAAAAAAED9olsZAAAAAABAHSM5BAAAAAAAUMdIDgEAAAAAANQxkkMAAAAAAAB1jOQQAAAAAABAHSM5BAAAAAAAUMdIDgEAAAAAANQxkkMAAAAAAAB17P8D9wt4XMt0h6wAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 1440x360 with 2 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "#糖尿病数据集上学习的神经网络的第一层权重热图\n",
    "plt.figure(figsize=(20, 5))\n",
    "plt.imshow(mlp.coefs_[0], interpolation='none', cmap='viridis')\n",
    "plt.yticks(range(8), diabetes_features)\n",
    "plt.xlabel(\"Columns in weight matrix\")\n",
    "plt.ylabel(\"Input feature\")\n",
    "plt.colorbar()\n",
    "plt.savefig(\"神经网络的第一层权重热图\")\n",
    "#热图很模糊，想要看清楚哪一个特征度的重要性是不容易的"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.0"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}
